package com.eshop.modules.activity.domain;

import java.math.BigDecimal;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModelProperty;
import io.swagger.annotations.ApiModel;
import com.eshop.domain.BaseDomain;

@ApiModel(value = "YxStoreBargainUser对象", description = "用户参与砍价表")
public class StoreBargainUser extends BaseDomain
{
    private static final long serialVersionUID = 1L;
    @ApiModelProperty("用户参与砍价表ID")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    @ApiModelProperty("用户ID")
    private Long uid;
    @ApiModelProperty("砍价产品id")
    private Long bargainId;
    @ApiModelProperty("砍价的最低价")
    private BigDecimal bargainPriceMin;
    @ApiModelProperty("砍价金额")
    private BigDecimal bargainPrice;
    @ApiModelProperty("砍掉的价格")
    private BigDecimal price;
    @ApiModelProperty("状态 1参与中 2 活动结束参与失败 3活动结束参与成功")
    private Integer status;
    
    public static StoreBargainUserBuilder builder() {
        return new StoreBargainUserBuilder();
    }
    
    public Long getId() {
        return this.id;
    }
    
    public Long getUid() {
        return this.uid;
    }
    
    public Long getBargainId() {
        return this.bargainId;
    }
    
    public BigDecimal getBargainPriceMin() {
        return this.bargainPriceMin;
    }
    
    public BigDecimal getBargainPrice() {
        return this.bargainPrice;
    }
    
    public BigDecimal getPrice() {
        return this.price;
    }
    
    public Integer getStatus() {
        return this.status;
    }
    
    public void setId(final Long id) {
        this.id = id;
    }
    
    public void setUid(final Long uid) {
        this.uid = uid;
    }
    
    public void setBargainId(final Long bargainId) {
        this.bargainId = bargainId;
    }
    
    public void setBargainPriceMin(final BigDecimal bargainPriceMin) {
        this.bargainPriceMin = bargainPriceMin;
    }
    
    public void setBargainPrice(final BigDecimal bargainPrice) {
        this.bargainPrice = bargainPrice;
    }
    
    public void setPrice(final BigDecimal price) {
        this.price = price;
    }
    
    public void setStatus(final Integer status) {
        this.status = status;
    }
    
    public String toString() {
        return "StoreBargainUser(id=" + this.getId() + ", uid=" + this.getUid() + ", bargainId=" + this.getBargainId() + ", bargainPriceMin=" + this.getBargainPriceMin() + ", bargainPrice=" + this.getBargainPrice() + ", price=" + this.getPrice() + ", status=" + this.getStatus() + ")";
    }
    
    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        }
        if (!(o instanceof StoreBargainUser)) {
            return false;
        }
        final StoreBargainUser other = (StoreBargainUser)o;
        if (!other.canEqual(this)) {
            return false;
        }
        if (!super.equals(o)) {
            return false;
        }
        final Object this$id = this.getId();
        final Object other$id = other.getId();
        Label_0075: {
            if (this$id == null) {
                if (other$id == null) {
                    break Label_0075;
                }
            }
            else if (this$id.equals(other$id)) {
                break Label_0075;
            }
            return false;
        }
        final Object this$uid = this.getUid();
        final Object other$uid = other.getUid();
        Label_0112: {
            if (this$uid == null) {
                if (other$uid == null) {
                    break Label_0112;
                }
            }
            else if (this$uid.equals(other$uid)) {
                break Label_0112;
            }
            return false;
        }
        final Object this$bargainId = this.getBargainId();
        final Object other$bargainId = other.getBargainId();
        Label_0149: {
            if (this$bargainId == null) {
                if (other$bargainId == null) {
                    break Label_0149;
                }
            }
            else if (this$bargainId.equals(other$bargainId)) {
                break Label_0149;
            }
            return false;
        }
        final Object this$status = this.getStatus();
        final Object other$status = other.getStatus();
        Label_0186: {
            if (this$status == null) {
                if (other$status == null) {
                    break Label_0186;
                }
            }
            else if (this$status.equals(other$status)) {
                break Label_0186;
            }
            return false;
        }
        final Object this$bargainPriceMin = this.getBargainPriceMin();
        final Object other$bargainPriceMin = other.getBargainPriceMin();
        Label_0223: {
            if (this$bargainPriceMin == null) {
                if (other$bargainPriceMin == null) {
                    break Label_0223;
                }
            }
            else if (this$bargainPriceMin.equals(other$bargainPriceMin)) {
                break Label_0223;
            }
            return false;
        }
        final Object this$bargainPrice = this.getBargainPrice();
        final Object other$bargainPrice = other.getBargainPrice();
        Label_0260: {
            if (this$bargainPrice == null) {
                if (other$bargainPrice == null) {
                    break Label_0260;
                }
            }
            else if (this$bargainPrice.equals(other$bargainPrice)) {
                break Label_0260;
            }
            return false;
        }
        final Object this$price = this.getPrice();
        final Object other$price = other.getPrice();
        if (this$price == null) {
            if (other$price == null) {
                return true;
            }
        }
        else if (this$price.equals(other$price)) {
            return true;
        }
        return false;
    }
    
    protected boolean canEqual(final Object other) {
        return other instanceof StoreBargainUser;
    }
    
    public int hashCode() {
        final int PRIME = 59;
        int result = super.hashCode();
        final Object $id = this.getId();
        result = result * 59 + (($id == null) ? 43 : $id.hashCode());
        final Object $uid = this.getUid();
        result = result * 59 + (($uid == null) ? 43 : $uid.hashCode());
        final Object $bargainId = this.getBargainId();
        result = result * 59 + (($bargainId == null) ? 43 : $bargainId.hashCode());
        final Object $status = this.getStatus();
        result = result * 59 + (($status == null) ? 43 : $status.hashCode());
        final Object $bargainPriceMin = this.getBargainPriceMin();
        result = result * 59 + (($bargainPriceMin == null) ? 43 : $bargainPriceMin.hashCode());
        final Object $bargainPrice = this.getBargainPrice();
        result = result * 59 + (($bargainPrice == null) ? 43 : $bargainPrice.hashCode());
        final Object $price = this.getPrice();
        result = result * 59 + (($price == null) ? 43 : $price.hashCode());
        return result;
    }
    
    public StoreBargainUser() {
    }
    
    public StoreBargainUser(final Long id, final Long uid, final Long bargainId, final BigDecimal bargainPriceMin, final BigDecimal bargainPrice, final BigDecimal price, final Integer status) {
        this.id = id;
        this.uid = uid;
        this.bargainId = bargainId;
        this.bargainPriceMin = bargainPriceMin;
        this.bargainPrice = bargainPrice;
        this.price = price;
        this.status = status;
    }
    
    public static class StoreBargainUserBuilder
    {
        private Long id;
        private Long uid;
        private Long bargainId;
        private BigDecimal bargainPriceMin;
        private BigDecimal bargainPrice;
        private BigDecimal price;
        private Integer status;
        
        StoreBargainUserBuilder() {
        }
        
        public StoreBargainUserBuilder id(final Long id) {
            this.id = id;
            return this;
        }
        
        public StoreBargainUserBuilder uid(final Long uid) {
            this.uid = uid;
            return this;
        }
        
        public StoreBargainUserBuilder bargainId(final Long bargainId) {
            this.bargainId = bargainId;
            return this;
        }
        
        public StoreBargainUserBuilder bargainPriceMin(final BigDecimal bargainPriceMin) {
            this.bargainPriceMin = bargainPriceMin;
            return this;
        }
        
        public StoreBargainUserBuilder bargainPrice(final BigDecimal bargainPrice) {
            this.bargainPrice = bargainPrice;
            return this;
        }
        
        public StoreBargainUserBuilder price(final BigDecimal price) {
            this.price = price;
            return this;
        }
        
        public StoreBargainUserBuilder status(final Integer status) {
            this.status = status;
            return this;
        }
        
        public StoreBargainUser build() {
            return new StoreBargainUser(this.id, this.uid, this.bargainId, this.bargainPriceMin, this.bargainPrice, this.price, this.status);
        }
        
        @Override
        public String toString() {
            return "StoreBargainUser.StoreBargainUserBuilder(id=" + this.id + ", uid=" + this.uid + ", bargainId=" + this.bargainId + ", bargainPriceMin=" + this.bargainPriceMin + ", bargainPrice=" + this.bargainPrice + ", price=" + this.price + ", status=" + this.status + ")";
        }
    }
}
